package com.rr.springcloud.client;

import com.rr.springcloud.vo.ResultVo;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.stereotype.Component;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;

/**
 * @author RR
 * @date 2021/3/27 17:10
 */
@Component
//注意写入服务名
@FeignClient("PAYMENT-SERVICE")
public interface PaymentFeignService {

    @GetMapping("/payment/get/{id}")
    ResultVo getPayment(@PathVariable("id") Long id);

    @GetMapping("/payment/feignTimeout")
    String timeoutTest();

}
